<template>
  <div class="b-container">
    <div>B组件-{{ money }}</div>
    <div>car:{{ car }}</div>
  </div>
</template>

<script setup>
import { inject } from 'vue'
defineProps(['money'])

const car = inject('car')
</script>

<style>
.b-container {
  border: 5px solid #396a5f;
  padding: 3px;
  width: 300px;
  height: 300px;
  margin: 10px auto;
}
</style>